<!-- template inhertance -->
<extend name="layout/layui24"/>

<!-- styles -->
<block name="linkcss">

</block>

<!-- scripts -->
<block name="linkjs">

</block>

<!-- page title -->
<block name="webtitle">
    <title>客户信息</title>
</block>

<!-- navagations -->
<block name="breadcrumb">
    <ol class="breadcrumb breadcrumb-edit">
        <li class="active">客户信息</li>
    </ol>
</block>

<!-- main body -->
<block name="content">
    {//只有销售才能创建}
    <if condition="$lists">
        <a href="customersCreate" class="btn btn-default">
            <i class="icon-plus"></i>
            添加客户
        </a>
    </if>

    <div class="mt-20">
        {//创建者只能看到自己及下属（汇报关系）创建的客户信息}
        <if condition="$lists">
            <table class="table table-hover">
                <thead>
                <tr>
                    <th>客户编号</th>
                    <th>评审状态</th>
                    <th>客户简称</th>
                    <th>客户联系人</th>
                    <th>创建者</th>
                    <th>创建时间</th>
                </tr>
                </thead>
                <tbody>
                <volist name="lists" id="vo">
                    <tr>
                        <td>
                            <a href="/Forms/customersShow?id={$vo.id}">{$vo.no}</a>
                        </td>
                        <td>
                            <switch name="vo.status">
                                <case value="1">
                                    <span class="tag tag-warning">待评审</span>
                                </case>
                                <case value="2">
                                    <span class="tag tag-info">评审中</span>
                                </case>
                                <case value="3">
                                    <span class="tag tag-success">已生效</span>
                                </case>
                                <default/>
                                <span class="tag tag-danger">已拒绝</span>
                            </switch>
                        </td>
                        <td>{$vo.customer}</td>
                        <td>{$vo.atten}</td>
                        <td>{$vo.create_user}</td>
                        <td>{$vo.create_time|date="Y-m-d H:i:s",###}</td>
                    </tr>
                </volist>
                </tbody>
            </table>

            <!-- 分页 -->
            <ul class="pagination pagination-edit">{$page}</ul>
            <else/>
            <div class="no--info"></div>
        </if>
    </div>
</block>